package com.jprocms.module.cms.dal.dataobject.investigateopinion;

import com.jpro.framework.tenant.core.db.TenantBaseDO;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.*;

/**
 * 问卷调查提交反馈 DO
 *
 * @author jprocms
 */
@TableName("cms_investigate_opinion")
@KeySequence("cms_investigate_opinion_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库，可不写。
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class InvestigateOpinionDO extends TenantBaseDO {

    /**
     * ID
     */
    @TableId
    private Long id;
    /**
     * 站点ID
     */
    private Long siteId;
    /**
     * 问卷ID
     */
    private Long investigateId;
    /**
     * 用户ID
     */
    private Long userId;
    /**
     * IP地址
     */
    private String ip;
    /**
     * Cookie
     */
    private String cookie;

    public InvestigateOpinionDO(Long investigateId, Long siteId, Long userId, String ip, String cookie) {
        this.siteId = siteId;
        this.investigateId = investigateId;
        this.userId = userId;
        this.ip = ip;
        this.cookie = cookie;
    }
}
